5.2 Main runs
# only keep the univariate data for E1
df_univar_agg_E1 <- {
df_univar_agg %>%
filter(ExpCode == 1) %>%
mutate(FaceWord = factor(FaceWord, levels = facewordOrder),
SubjCode = as.factor(SubjCode))
}
# only keep the multivariate (mvpa) data for E1
df_mvpa_acc_E1 <- {
df_mvpa_acc %>%
filter(ExpCode == 1) %>%
mutate(ClassifyPair = factor(ClassifyPair, levels = pairOrder_E1),
SubjCode = as.factor(SubjCode))
}
# only keep the similarity for E1
df_rate_simi_E1 <- {
df_rate_simi %>%
filter(ExpCode == 1) %>%
mutate(SubjCode = as.factor(SubjCode))
}
5.2.1 Label:FFA
# label_lFFA_E1 <- label_lFFA[1] # "roi.lh.f20.f-vs-o.label" "roi.lh.f40.f-vs-o.label"
# label_rFFA_E1 <- label_rFFA[1] # "roi.rh.f20.f-vs-o.label" "roi.rh.f40.f-vs-o.label"
label_FFA_E1 <- c(label_lFFA_E1, label_rFFA_E1)
The label used for left FFA in Experiment 1 is roi.lh.f20.f-vs-o.label.
The label used for right FFA in Experiment 1 is roi.rh.f20.f-vs-o.label.
# only keep data for these two labels
df_univar_agg_E1_FFA <- filter(df_univar_agg_E1, Label %in% label_FFA_E1)
df_mvpa_acc_E1_FFA <- filter(df_mvpa_acc_E1, Label %in% label_FFA_E1)
df_simi_rate_E1_FFA <- filter(df_rate_simi_E1, Label %in% label_FFA_E1)
# subjects used for each hemisphere
# unique(as.character((df_univar_agg_E1_FFA %>% filter(Label == label_rFFA_E1))$SubjCode))
df_univar_agg_E1_FFA %>%
select(ExpCode, Hemisphere, Label, SubjCode) %>%
distinct() %>%
group_by(ExpCode, Hemisphere, Label) %>%
summarize(Count = n())
5.2.1.1 Univariate analyses
5.2.1.1.1 rm-ANOVA
5.2.1.1.1.1 Left FFA
anova_E1_lFFA <- aov_4(meanResp ~ FaceWord * Layout + (1 + FaceWord * Layout | SubjCode),
data = filter(df_univar_agg_E1_FFA, Label == label_lFFA_E1))
anova_E1_lFFA
## Anova Table (Type 3 tests)
##
## Response: meanResp
## Effect df MSE F ges p.value
## 1 FaceWord 1, 11 0.19 2.92 .03 .12
## 2 Layout 2.20, 24.17 0.03 7.35 ** .03 .003
## 3 FaceWord:Layout 2.19, 24.14 0.06 0.60 .004 .57
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '+' 0.1 ' ' 1
##
## Sphericity correction method: GG
emm_anova_E1_lFFA <- emmeans(anova_E1_lFFA, ~ FaceWord * Layout)
emm_anova_E1_lFFA %>%
as.data.frame() %>%
arrange(FaceWord)
Posthoc analysis for the main effects:
contrast(emmeans(emm_anova_E1_lFFA, ~ FaceWord), "pairwise")
## contrast estimate SE df t.ratio p.value
## face - word 0.153 0.0899 11 1.707 0.1158
##
## Results are averaged over the levels of: Layout
contrast(emmeans(emm_anova_E1_lFFA, ~ Layout), "pairwise") # , adjust = "none"
## contrast estimate SE df t.ratio p.value
## intact - misconfigured 0.0952 0.0462 33 2.061 0.1871
## intact - top 0.2145 0.0462 33 4.643 0.0003
## intact - bottom 0.0794 0.0462 33 1.720 0.3300
## misconfigured - top 0.1193 0.0462 33 2.583 0.0656
## misconfigured - bottom -0.0158 0.0462 33 -0.341 0.9861
## top - bottom -0.1350 0.0462 33 -2.924 0.0301
##
## Results are averaged over the levels of: FaceWord
## P value adjustment: tukey method for comparing a family of 4 estimates
Results of simple effect analysis (uncorrected):
contr_anova_E1_lFFA <- contrast(emm_anova_E1_lFFA, "pairwise", simple = "each", combine = TRUE, adjust = "none")
# contrast(emm_uni_anova_E1, interaction = "pairwise") # , adjust = "none"
contr_anova_E1_lFFA
## Layout FaceWord contrast estimate SE df t.ratio p.value
## intact . face - word 0.23780 0.1170 27.2 2.033 0.0519
## misconfigured . face - word 0.17662 0.1170 27.2 1.510 0.1426
## top . face - word 0.10059 0.1170 27.2 0.860 0.3974
## bottom . face - word 0.09870 0.1170 27.2 0.844 0.4062
## . face intact - misconfigured 0.12577 0.0766 61.4 1.641 0.1059
## . face intact - top 0.28306 0.0766 61.4 3.693 0.0005
## . face intact - bottom 0.14897 0.0766 61.4 1.944 0.0565
## . face misconfigured - top 0.15729 0.0766 61.4 2.052 0.0444
## . face misconfigured - bottom 0.02320 0.0766 61.4 0.303 0.7631
## . face top - bottom -0.13409 0.0766 61.4 -1.750 0.0852
## . word intact - misconfigured 0.06459 0.0766 61.4 0.843 0.4027
## . word intact - top 0.14585 0.0766 61.4 1.903 0.0617
## . word intact - bottom 0.00987 0.0766 61.4 0.129 0.8980
## . word misconfigured - top 0.08126 0.0766 61.4 1.060 0.2932
## . word misconfigured - bottom -0.05472 0.0766 61.4 -0.714 0.4780
## . word top - bottom -0.13598 0.0766 61.4 -1.774 0.0810
5.2.1.1.1.2 Right FFA
anova_E1_rFFA <- aov_4(meanResp ~ FaceWord * Layout + (1 + FaceWord * Layout | SubjCode),
data = filter(df_univar_agg_E1_FFA, Label == label_rFFA_E1))
anova_E1_rFFA
## Anova Table (Type 3 tests)
##
## Response: meanResp
## Effect df MSE F ges p.value
## 1 FaceWord 1, 15 0.28 21.21 *** .12 .0003
## 2 Layout 2.51, 37.67 0.03 10.53 *** .02 <.0001
## 3 FaceWord:Layout 2.12, 31.84 0.06 3.85 * .01 .03
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '+' 0.1 ' ' 1
##
## Sphericity correction method: GG
emm_anova_E1_rFFA <- emmeans(anova_E1_rFFA, ~ FaceWord * Layout)
emm_anova_E1_rFFA %>%
as.data.frame() %>%
arrange(FaceWord)
Posthoc analysis for the main effects:
contrast(emmeans(emm_anova_E1_rFFA, ~ FaceWord), "pairwise")
## contrast estimate SE df t.ratio p.value
## face - word 0.427 0.0927 15 4.606 0.0003
##
## Results are averaged over the levels of: Layout
contrast(emmeans(emm_anova_E1_rFFA, ~ Layout), "pairwise") # , adjust = "none"
## contrast estimate SE df t.ratio p.value
## intact - misconfigured 0.1822 0.0402 45 4.529 0.0002
## intact - top 0.1980 0.0402 45 4.922 0.0001
## intact - bottom 0.1692 0.0402 45 4.206 0.0007
## misconfigured - top 0.0158 0.0402 45 0.393 0.9792
## misconfigured - bottom -0.0130 0.0402 45 -0.324 0.9881
## top - bottom -0.0288 0.0402 45 -0.716 0.8900
##
## Results are averaged over the levels of: FaceWord
## P value adjustment: tukey method for comparing a family of 4 estimates
Results of simple effect analysis (uncorrected):
contr_anova_E1_rFFA <- contrast(emm_anova_E1_rFFA, "pairwise", simple = "each", combine = TRUE, adjust = "none")
# contrast(emm_uni_anova_E1, interaction = "pairwise") # , adjust = "none"
contr_anova_E1_rFFA
## Layout FaceWord contrast estimate SE df t.ratio p.value
## intact . face - word 0.63714 0.1117 29.6 5.702 <.0001
## misconfigured . face - word 0.34458 0.1117 29.6 3.084 0.0044
## top . face - word 0.38306 0.1117 29.6 3.428 0.0018
## bottom . face - word 0.34325 0.1117 29.6 3.072 0.0045
## . face intact - misconfigured 0.32852 0.0649 85.4 5.062 <.0001
## . face intact - top 0.32508 0.0649 85.4 5.009 <.0001
## . face intact - bottom 0.31616 0.0649 85.4 4.872 <.0001
## . face misconfigured - top -0.00344 0.0649 85.4 -0.053 0.9579
## . face misconfigured - bottom -0.01236 0.0649 85.4 -0.190 0.8495
## . face top - bottom -0.00892 0.0649 85.4 -0.137 0.8910
## . word intact - misconfigured 0.03596 0.0649 85.4 0.554 0.5810
## . word intact - top 0.07101 0.0649 85.4 1.094 0.2770
## . word intact - bottom 0.02227 0.0649 85.4 0.343 0.7323
## . word misconfigured - top 0.03505 0.0649 85.4 0.540 0.5905
## . word misconfigured - bottom -0.01369 0.0649 85.4 -0.211 0.8335
## . word top - bottom -0.04874 0.0649 85.4 -0.751 0.4547
5.2.1.1.2 Plot
sig_uni_E1_FFA <- c(signif(as.data.frame(contr_anova_E1_lFFA)[c(5, 11), "p.value"], nDigitals), rep("", 6),
signif(as.data.frame(contr_anova_E1_rFFA)[c(5, 11), "p.value"], nDigitals), rep("", 6))
color_uni_E1_FFA <- sig_colors(sig_uni_E1_FFA)
# add the column of Hemisphere
nRow_E1 <-nrow(as.data.frame(emm_anova_E1_lFFA))
Hemisphere <- c(rep("left", nRow_E1), rep("right", nRow_E1))
desp_uni_E1_FFA <- cbind(Hemisphere, rbind(as.data.frame(emm_anova_E1_lFFA), as.data.frame(emm_anova_E1_rFFA)))
plot_uni_E1_FFA <- {
ggplot(data = desp_uni_E1_FFA, aes(y = emmean, x = Hemisphere, fill = Layout)) + # set the data, varialbes for x and y axises
geom_col(position = "dodge", color = "black", alpha = .7) + # position of columns and countour of columns
facet_grid(FaceWord ~ .) +
geom_errorbar(mapping = aes(ymin = lower.CL, ymax = upper.CL), linetype = 1, # set the error bar
show.legend = FALSE, width = 0.25, alpha = .5,
position = position_dodge(width=0.9)) +
scale_y_continuous(expand= c(0, 0), limits = c(0, activationUL), breaks = seq(0, 3, .5)) + # remove the space between columns and x axis
labs(title = "Mean neural responses in FFA (Univariate)", x = "Hemisphere", y = "Beta values") + # set the names for main, x and y axises
geom_text(label = sig_uni_E1_FFA, color = color_uni_E1_FFA, size = sig_size, nudge_y = 0.5, nudge_x = -0.25) + # add starts to the significant columns
general_theme
}
# ggsave('plot_uni_E1_FFA.png', plot_uni_E1_FFA, width = 8, height = 5.5)
plot_uni_E1_FFA
The above figure shows the neural respones (beta values) in FFA for each condition. The numbers are the p-values for the tests of differences between intact vs. misconfigued in that condition. Error bars represent 95% confidence intervals.
5.2.1.2 Multivarate analyses (MVPA)
5.2.1.2.1 One-sample t-test
one_mvpa_agg_E1_FFA <- {
df_mvpa_acc_E1_FFA %>%
group_by(Hemisphere, ClassifyPair) %>%
summarize(mean = t.test(Accuracy, mu = 0.5, alternative = "greater")[[5]],
SD = t.test(Accuracy, mu = 0.5, alternative = "greater")[[7]],
t = t.test(Accuracy, mu = 0.5, alternative = "greater")[[1]],
df = t.test(Accuracy, mu = 0.5, alternative = "greater")[[2]],
p = round(t.test(Accuracy, mu = 0.5, alternative = "greater")[[3]], 5),
lower.CL = t.test(Accuracy, mu = 0.5, alternative = "greater")[[4]][1],
upper.CL = mean * 2 - lower.CL, # t.test(Accuracy, mu = 0.5, alternative = "two.sided")[[4]][2],
nullValue = t.test(Accuracy, mu = 0.5, alternative = "greater")[[6]],
alternative = t.test(Accuracy, mu = 0.5, alternative = "greater")[[8]]
)
}
one_mvpa_agg_E1_FFA
5.2.1.2.2 Plot
plot_mvpa_E1_FFA <- {
ggplot(data = one_mvpa_agg_E1_FFA, aes(y = mean, x = ClassifyPair, fill = ClassifyPair)) + # set the data, varialbes for x and y axises
geom_col(position = "dodge", color = "black", alpha = .7) + # position of columns and countour of columns
facet_grid(. ~ Hemisphere) +
scale_fill_manual(values = mvpaColors) +
geom_errorbar(mapping = aes(ymin = lower.CL, ymax = upper.CL), linetype = 1, # set the error bar
show.legend = FALSE, width = 0.25, alpha = .5,
position = position_dodge(width=0.9)) +
geom_hline(yintercept = c(0.5, 1), linetype = 5, alpha = 0.5) + # add the line for 0.5 and 1 (y)
scale_y_continuous(expand= c(0, 0), limits = c(0, 1.1), breaks = seq(0, 1, .25)) + # remove the space between columns and x axis
# scale_x_discrete(labels = function(x) str_wrap(x, width = 10)) + # show x labels in two rows
labs(title = "Decoding accuracy in FFA", x = "Classification Pairs", y = "Accuracy") + # set the names for main, x and y axises
geom_text(label = signif(one_mvpa_agg_E1_FFA$p), color = sig_colors(one_mvpa_agg_E1_FFA$p), size = sig_size, nudge_y = 0.15) + # add starts to the significant columns
general_theme +
theme(axis.title.x=element_blank(),
axis.text.x=element_blank(),
axis.ticks.x=element_blank(),
axis.line = element_line(size = 3))
# theme(axis.text.x = element_text(angle = 90, vjust=.5, hjust = 1), #
# axis.line = element_line(size = 3))
}
# ggsave('plot_mvpa_E1_FFA.png', plot_mvpa_E1_FFA, width = 12, height = 5)
plot_mvpa_E1_FFA
The above figure shows the decoding accuracy in FFA for each pair. The numbers are the p-values for the one-tail one-sample t-tests against the chance level (0.5) in that condition. Error bars represent 95% confidence intervals.
5.2.1.3 Similarity of top + bottom to intact vs. misconfigured
5.2.1.3.1 One-sample t-test
# Similarity of top + bottom to intact vs. misconfigured in FFA
one_simi_E1_FFA <- {
df_simi_rate_E1_FFA %>%
group_by(Hemisphere, Combination) %>%
summarize(mean = t.test(RateAsMiscon, mu = 0.5)[[5]],
SD = t.test(RateAsMiscon, mu = 0.5)[[7]],
t = t.test(RateAsMiscon, mu = 0.5)[[1]],
df = t.test(RateAsMiscon, mu = 0.5)[[2]],
p = round(t.test(RateAsMiscon, mu = 0.5)[[3]], 5),
lower.CL = t.test(RateAsMiscon, mu = 0.5)[[4]][1],
upper.CL = t.test(RateAsMiscon, mu = 0.5)[[4]][2],
nullValue = t.test(RateAsMiscon, mu = 0.5)[[6]],
alternative = t.test(RateAsMiscon, mu = 0.5)[[8]]
)
}
one_simi_E1_FFA
5.2.1.3.2 Plot
plot_simi_E1_FFA <- {
ggplot(data = one_simi_E1_FFA, aes(y = mean, x = Combination, fill = Combination)) + # set the data, varialbes for x and y axises
geom_col(position = "dodge", color = "black", alpha = .7) + # position of columns and countour of columns
facet_grid(. ~ Hemisphere) +
geom_errorbar(mapping = aes(ymin = lower.CL, ymax = upper.CL), linetype = 1, # set the error bar
show.legend = FALSE, width = 0.25, alpha = .5,
position = position_dodge(width=0.9)) +
scale_fill_manual(values = simiColors) +
geom_hline(yintercept = c(0.5, 1), linetype = 5, alpha = 0.5) + # add the line for 0.5 and 1 (y)
scale_y_continuous(expand= c(0, 0), limits = c(0, 1.1), breaks = seq(0, 1, .25)) + # remove the space between columns and x axis
# scale_x_discrete(labels = function(x) str_wrap(x, width = 10)) + # show x labels in two rows
labs(title = "Similarity of top+bottom to intact vs. misconfigured in FFA", x = "Combinations", y = "Rate of Decoding as Misconfigured") + # set the names for main, x and y axises
geom_text(label = signif(one_simi_E1_FFA$p, 4), color = sig_colors(one_simi_E1_FFA$p), size = sig_size, nudge_y = 0.25) + # add starts to the significant columns
general_theme +
theme(axis.title.x=element_blank(),
axis.text.x=element_blank(),
axis.ticks.x=element_blank(),
axis.line = element_line(size = 4))
# theme(axis.text.x = element_text(angle = 90, vjust=.5, hjust = 1), #
# axis.line = element_line(size = 3))
}
# ggsave('plot_simi_E1_FFA.png', plot_simi_E1_FFA, width = 14, height = 5)
plot_simi_E1_FFA
The above figure shows the probability of top+bottom being decoded as misconfigued conditions in FFA. Patterns of top and bottom were combined with different weights, i.e., “face_top0.25-face_bottom0.75” denotes the linear combinations of face_top and face_bottom with the weights of 0.25/0.75. The numbers are the p-values for the two-tail one-sample t-tests against the chance level (0.5) in that condition. Error bars represent 95% confidence intervals.
5.2.2 Label:FFA1
# label_lFFA1_E1 <- label_lFFA1[1] # "roi.lh.f13.f-vs-o.ffa1.label" "roi.lh.f20.f-vs-o.ffa1.label"
# label_rFFA1_E1 <- label_rFFA1[1] # "roi.rh.f13.f-vs-o.ffa1.label"
label_FFA1_E1 <- c(label_lFFA1_E1, label_rFFA1_E1)
The label used for left FFA1 in Experiment 1 is roi.lh.f13.f-vs-o.ffa1.label.
The label used for right FFA1 in Experiment 1 is roi.rh.f13.f-vs-o.ffa1.label.
# only keep data for these two labels
df_univar_agg_E1_FFA1 <- filter(df_univar_agg_E1, Label %in% label_FFA1_E1)
df_mvpa_acc_E1_FFA1 <- filter(df_mvpa_acc_E1, Label %in% label_FFA1_E1)
df_simi_rate_E1_FFA1 <- filter(df_rate_simi_E1, Label %in% label_FFA1_E1)
# subjects used for each hemisphere
# unique(as.character((df_univar_agg_E1_FFA1 %>% filter(Label == label_rFFA1_E1))$SubjCode))
df_univar_agg_E1_FFA1 %>%
select(ExpCode, Hemisphere, Label, SubjCode) %>%
distinct() %>%
group_by(ExpCode, Hemisphere, Label) %>%
summarize(Count = n())
5.2.2.1 Univariate analyses
5.2.2.1.1 rm-ANOVA
5.2.2.1.1.1 Left FFA1
anova_E1_lFFA1 <- aov_4(meanResp ~ FaceWord * Layout + (1 + FaceWord * Layout | SubjCode),
data = filter(df_univar_agg_E1_FFA1, Label == label_lFFA1_E1))
anova_E1_lFFA1
## Anova Table (Type 3 tests)
##
## Response: meanResp
## Effect df MSE F ges p.value
## 1 FaceWord 1, 11 0.28 4.52 + .10 .06
## 2 Layout 2.38, 26.17 0.03 9.19 *** .06 .0005
## 3 FaceWord:Layout 2.32, 25.50 0.04 2.07 .02 .14
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '+' 0.1 ' ' 1
##
## Sphericity correction method: GG
emm_anova_E1_lFFA1 <- emmeans(anova_E1_lFFA1, ~ FaceWord * Layout)
emm_anova_E1_lFFA1 %>%
as.data.frame() %>%
arrange(FaceWord)
Posthoc analysis for the main effects:
contrast(emmeans(emm_anova_E1_lFFA1, ~ FaceWord), "pairwise")
## contrast estimate SE df t.ratio p.value
## face - word 0.229 0.108 11 2.127 0.0569
##
## Results are averaged over the levels of: Layout
contrast(emmeans(emm_anova_E1_lFFA1, ~ Layout), "pairwise") # , adjust = "none"
## contrast estimate SE df t.ratio p.value
## intact - misconfigured 0.0717 0.0459 33 1.564 0.4127
## intact - top 0.2274 0.0459 33 4.958 0.0001
## intact - bottom 0.1510 0.0459 33 3.294 0.0120
## misconfigured - top 0.1557 0.0459 33 3.395 0.0093
## misconfigured - bottom 0.0793 0.0459 33 1.730 0.3247
## top - bottom -0.0763 0.0459 33 -1.664 0.3581
##
## Results are averaged over the levels of: FaceWord
## P value adjustment: tukey method for comparing a family of 4 estimates
Results of simple effect analysis (uncorrected):
contr_anova_E1_lFFA1 <- contrast(emm_anova_E1_lFFA1, "pairwise", simple = "each", combine = TRUE, adjust = "none")
# contrast(emm_uni_anova_E1, interaction = "pairwise") # , adjust = "none"
contr_anova_E1_lFFA1
## Layout FaceWord contrast estimate SE df t.ratio p.value
## intact . face - word 0.34875 0.1250 19.2 2.789 0.0116
## misconfigured . face - word 0.15841 0.1250 19.2 1.267 0.2203
## top . face - word 0.28480 0.1250 19.2 2.278 0.0343
## bottom . face - word 0.12388 0.1250 19.2 0.991 0.3341
## . face intact - misconfigured 0.16687 0.0693 65.0 2.409 0.0189
## . face intact - top 0.25934 0.0693 65.0 3.743 0.0004
## . face intact - bottom 0.26348 0.0693 65.0 3.803 0.0003
## . face misconfigured - top 0.09247 0.0693 65.0 1.335 0.1866
## . face misconfigured - bottom 0.09661 0.0693 65.0 1.394 0.1679
## . face top - bottom 0.00414 0.0693 65.0 0.060 0.9526
## . word intact - misconfigured -0.02347 0.0693 65.0 -0.339 0.7359
## . word intact - top 0.19540 0.0693 65.0 2.820 0.0064
## . word intact - bottom 0.03861 0.0693 65.0 0.557 0.5792
## . word misconfigured - top 0.21887 0.0693 65.0 3.159 0.0024
## . word misconfigured - bottom 0.06208 0.0693 65.0 0.896 0.3735
## . word top - bottom -0.15679 0.0693 65.0 -2.263 0.0270
5.2.2.1.1.2 Right FFA1
anova_E1_rFFA1 <- aov_4(meanResp ~ FaceWord * Layout + (1 + FaceWord * Layout | SubjCode),
data = filter(df_univar_agg_E1_FFA1, Label == label_rFFA1_E1))
anova_E1_rFFA1
## Anova Table (Type 3 tests)
##
## Response: meanResp
## Effect df MSE F ges p.value
## 1 FaceWord 1, 15 0.29 24.99 *** .15 .0002
## 2 Layout 2.03, 30.48 0.07 3.20 + .01 .05
## 3 FaceWord:Layout 2.49, 37.37 0.07 3.57 * .01 .03
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '+' 0.1 ' ' 1
##
## Sphericity correction method: GG
emm_anova_E1_rFFA1 <- emmeans(anova_E1_rFFA1, ~ FaceWord * Layout)
emm_anova_E1_rFFA1 %>%
as.data.frame() %>%
arrange(FaceWord)
Posthoc analysis for the main effects:
contrast(emmeans(emm_anova_E1_rFFA1, ~ FaceWord), "pairwise")
## contrast estimate SE df t.ratio p.value
## face - word 0.473 0.0947 15 4.999 0.0002
##
## Results are averaged over the levels of: Layout
contrast(emmeans(emm_anova_E1_rFFA1, ~ Layout), "pairwise") # , adjust = "none"
## contrast estimate SE df t.ratio p.value
## intact - misconfigured 0.1333 0.054 45 2.469 0.0788
## intact - top 0.1530 0.054 45 2.833 0.0335
## intact - bottom 0.0822 0.054 45 1.523 0.4325
## misconfigured - top 0.0197 0.054 45 0.364 0.9833
## misconfigured - bottom -0.0511 0.054 45 -0.945 0.7806
## top - bottom -0.0707 0.054 45 -1.310 0.5616
##
## Results are averaged over the levels of: FaceWord
## P value adjustment: tukey method for comparing a family of 4 estimates
Results of simple effect analysis (uncorrected):
contr_anova_E1_rFFA1 <- contrast(emm_anova_E1_rFFA1, "pairwise", simple = "each", combine = TRUE, adjust = "none")
# contrast(emm_uni_anova_E1, interaction = "pairwise") # , adjust = "none"
contr_anova_E1_rFFA1
## Layout FaceWord contrast estimate SE df t.ratio p.value
## intact . face - word 0.71392 0.1206 35.0 5.921 <.0001
## misconfigured . face - word 0.39410 0.1206 35.0 3.269 0.0024
## top . face - word 0.35859 0.1206 35.0 2.974 0.0053
## bottom . face - word 0.42642 0.1206 35.0 3.537 0.0012
## . face intact - misconfigured 0.29321 0.0814 88.7 3.601 0.0005
## . face intact - top 0.33064 0.0814 88.7 4.060 0.0001
## . face intact - bottom 0.22600 0.0814 88.7 2.775 0.0067
## . face misconfigured - top 0.03743 0.0814 88.7 0.460 0.6469
## . face misconfigured - bottom -0.06722 0.0814 88.7 -0.825 0.4113
## . face top - bottom -0.10464 0.0814 88.7 -1.285 0.2021
## . word intact - misconfigured -0.02661 0.0814 88.7 -0.327 0.7446
## . word intact - top -0.02469 0.0814 88.7 -0.303 0.7624
## . word intact - bottom -0.06151 0.0814 88.7 -0.755 0.4521
## . word misconfigured - top 0.00192 0.0814 88.7 0.024 0.9813
## . word misconfigured - bottom -0.03490 0.0814 88.7 -0.429 0.6693
## . word top - bottom -0.03681 0.0814 88.7 -0.452 0.6523
5.2.2.1.2 Plot
sig_uni_E1_FFA1 <- c(signif(as.data.frame(contr_anova_E1_lFFA1)[c(5, 11), "p.value"], nDigitals), rep("", 6),
signif(as.data.frame(contr_anova_E1_rFFA1)[c(5, 11), "p.value"], nDigitals), rep("", 6))
color_uni_E1_FFA1 <- sig_colors(sig_uni_E1_FFA1)
# add the column of Hemisphere
nRow_E1 <-nrow(as.data.frame(emm_anova_E1_lFFA1))
Hemisphere <- c(rep("left", nRow_E1), rep("right", nRow_E1))
desp_uni_E1_FFA1 <- cbind(Hemisphere, rbind(as.data.frame(emm_anova_E1_lFFA1), as.data.frame(emm_anova_E1_rFFA1)))
plot_uni_E1_FFA1 <- {
ggplot(data = desp_uni_E1_FFA1, aes(y = emmean, x = Hemisphere, fill = Layout)) + # set the data, varialbes for x and y axises
geom_col(position = "dodge", color = "black", alpha = .7) + # position of columns and countour of columns
facet_grid(FaceWord ~ .) +
geom_errorbar(mapping = aes(ymin = lower.CL, ymax = upper.CL), linetype = 1, # set the error bar
show.legend = FALSE, width = 0.25, alpha = .5,
position = position_dodge(width=0.9)) +
scale_y_continuous(expand= c(0, 0), limits = c(0, activationUL), breaks = seq(0, 3, .5)) + # remove the space between columns and x axis
labs(title = "Mean neural responses in FFA1 (Univariate)", x = "Hemisphere", y = "Beta values") + # set the names for main, x and y axises Subjective Responses for E205
geom_text(label = sig_uni_E1_FFA1, color = color_uni_E1_FFA1, size = 5, nudge_y = 0.5, nudge_x = -0.25) + # add starts to the significant columns
general_theme
}
# ggsave('plot_uni_E1_FFA1.png', plot_uni_E1_FFA1, width = 8, height = 5.5)
plot_uni_E1_FFA1
The above figure shows the neural respones (beta values) in FFA1 for each condition. The numbers are the p-values for the tests of differences between intact vs. misconfigued in that condition. Error bars represent 95% confidence intervals.
5.2.2.2 Multivarate analyses (MVPA)
5.2.2.2.1 One-sample t-test
# one-sample for results of mvpa E1 FFA1
one_mvpa_agg_E1_FFA1 <- {
df_mvpa_acc_E1_FFA1 %>%
group_by(Hemisphere, ClassifyPair) %>%
summarize(mean = t.test(Accuracy, mu = 0.5, alternative = "greater")[[5]],
SD = t.test(Accuracy, mu = 0.5, alternative = "greater")[[7]],
t = t.test(Accuracy, mu = 0.5, alternative = "greater")[[1]],
df = t.test(Accuracy, mu = 0.5, alternative = "greater")[[2]],
p = round(t.test(Accuracy, mu = 0.5, alternative = "greater")[[3]], 5),
lower.CL = t.test(Accuracy, mu = 0.5, alternative = "greater")[[4]][1],
upper.CL = mean * 2 - lower.CL, # t.test(Accuracy, mu = 0.5, alternative = "two.sided")[[4]][2],
nullValue = t.test(Accuracy, mu = 0.5, alternative = "greater")[[6]],
alternative = t.test(Accuracy, mu = 0.5, alternative = "greater")[[8]]
)
}
one_mvpa_agg_E1_FFA1
5.2.2.2.2 Plot
plot_mvpa_E1_FFA1 <- {
ggplot(data = one_mvpa_agg_E1_FFA1, aes(y = mean, x = ClassifyPair, fill = ClassifyPair)) + # set the data, varialbes for x and y axises
geom_col(position = "dodge", color = "black", alpha = .7) + # position of columns and countour of columns
facet_grid(. ~ Hemisphere) +
scale_fill_manual(values = mvpaColors) +
geom_errorbar(mapping = aes(ymin = lower.CL, ymax = upper.CL), linetype = 1, # set the error bar
show.legend = FALSE, width = 0.25, alpha = .5,
position = position_dodge(width=0.9)) +
geom_hline(yintercept = c(0.5, 1), linetype = 5, alpha = 0.5) + # add the line for 0.5 and 1 (y)
scale_y_continuous(expand= c(0, 0), limits = c(0, 1.1), breaks = seq(0, 1, .25)) + # remove the space between columns and x axis
labs(title = "Decoding accuracy in FFA1", x = "Classification Pairs", y = "Accuracy") + # set the names for main, x and y axises
geom_text(label = signif(one_mvpa_agg_E1_FFA1$p), color = sig_colors(one_mvpa_agg_E1_FFA1$p), size = sig_size, nudge_y = 0.15) + # add starts to the significant columns
general_theme +
theme(axis.title.x=element_blank(),
axis.text.x=element_blank(),
axis.ticks.x=element_blank(),
axis.line = element_line(size = 3))
# theme(axis.text.x = element_text(angle = 90, vjust=.5, hjust = 1), #
# axis.line = element_line(size = 3))
}
# ggsave('plot_mvpa_E1_FFA1.png', plot_mvpa_E1_FFA1, width = 12, height = 5)
plot_mvpa_E1_FFA1
The above figure shows the decoding accuracy in FFA1 for each pair. The numbers are the p-values for the one-tail one-sample t-tests against the chance level (0.5) in that condition. Error bars represent 95% confidence intervals.
5.2.2.3 Similarity of top + bottom to intact vs. misconfigured
5.2.2.3.1 One-sample t-test
one_simi_E1_FFA1 <- {
df_simi_rate_E1_FFA1 %>%
group_by(Hemisphere, Combination) %>%
summarize(mean = t.test(RateAsMiscon, mu = 0.5)[[5]],
SD = t.test(RateAsMiscon, mu = 0.5)[[7]],
t = t.test(RateAsMiscon, mu = 0.5)[[1]],
df = t.test(RateAsMiscon, mu = 0.5)[[2]],
p = round(t.test(RateAsMiscon, mu = 0.5)[[3]], 5),
lower.CL = t.test(RateAsMiscon, mu = 0.5)[[4]][1],
upper.CL = t.test(RateAsMiscon, mu = 0.5)[[4]][2],
nullValue = t.test(RateAsMiscon, mu = 0.5)[[6]],
alternative = t.test(RateAsMiscon, mu = 0.5)[[8]]
)
}
one_simi_E1_FFA1
5.2.2.3.2 Plot
plot_simi_E1_FFA1 <- {
ggplot(data = one_simi_E1_FFA1, aes(y = mean, x = Combination, fill = Combination)) + # set the data, varialbes for x and y axises
geom_col(position = "dodge", color = "black", alpha = .7) + # position of columns and countour of columns
facet_grid(. ~ Hemisphere) +
geom_errorbar(mapping = aes(ymin = lower.CL, ymax = upper.CL), linetype = 1, # set the error bar
show.legend = FALSE, width = 0.25, alpha = .5,
position = position_dodge(width=0.9)) +
scale_fill_manual(values = simiColors) +
geom_hline(yintercept = c(0.5, 1), linetype = 5, alpha = 0.5) + # add the line for 0.5 and 1 (y)
scale_y_continuous(expand= c(0, 0), limits = c(0, 1.1), breaks = seq(0, 1, .25)) + # remove the space between columns and x axis
# scale_x_discrete(labels = function(x) str_wrap(x, width = 10)) + # show x labels in two rows
labs(title = "Similarity of top+bottom to intact vs. misconfigured in FFA1", x = "Combinations", y = "Rate of Decoding as Misconfigured") + # set the names for main, x and y axises
geom_text(label = signif(one_simi_E1_FFA1$p,4), color = sig_colors(one_simi_E1_FFA1$p), size = sig_size, nudge_y = 0.25) + # add starts to the significant columns
general_theme +
theme(axis.title.x=element_blank(),
axis.text.x=element_blank(),
axis.ticks.x=element_blank(),
axis.line = element_line(size = 4))
# theme(axis.text.x = element_text(angle = 90, vjust=.5, hjust = 1), #
# axis.line = element_line(size = 3))
}
# ggsave('plot_simi_E1_FFA1.png', plot_simi_E1_FFA1, width = 14, height = 5)
plot_simi_E1_FFA
The above figure shows the probability of top+bottom being decoded as misconfigued conditions in FFA1. Patterns of top and bottom were combined with different weights, i.e., “face_top0.25-face_bottom0.75” denotes the linear combinations of face_top and face_bottom with the weights of 0.25/0.75. The numbers are the p-values for the two-tail one-sample t-tests against the chance level (0.5) in that condition. Error bars represent 95% confidence intervals.
5.2.3 Label:FFA2
# label_lFFA2_E1 <- label_lFFA2[1] # "roi.lh.f13.f-vs-o.ffa2.label"
# label_rFFA2_E1 <- label_rFFA2[1] # "roi.rh.f20.f-vs-o.ffa2.label" "roi.rh.f40.f-vs-o.ffa2.label"
label_FFA2_E1 <- c(label_lFFA2_E1, label_rFFA2_E1)
The label used for left FFA2 in Experiment 1 is roi.lh.f13.f-vs-o.ffa2.label.
The label used for right FFA2 in Experiment 1 is roi.rh.f13.f-vs-o.ffa2.label.
# only keep data for these two labels
df_univar_agg_E1_FFA2 <- filter(df_univar_agg_E1, Label %in% label_FFA2_E1)
df_mvpa_acc_E1_FFA2 <- filter(df_mvpa_acc_E1, Label %in% label_FFA2_E1)
df_simi_rate_E1_FFA2 <- filter(df_rate_simi_E1, Label %in% label_FFA2_E1)
# subjects used for each hemisphere
# unique(as.character((df_univar_agg_E1_FFA2 %>% filter(Label == label_lFFA2_E1))$SubjCode))
df_univar_agg_E1_FFA2 %>%
select(ExpCode, Hemisphere, Label, SubjCode) %>%
distinct() %>%
group_by(ExpCode, Hemisphere, Label) %>%
summarize(Count = n())
5.2.3.1 Univariate analyses
5.2.3.1.1 rm-ANOVA
5.2.3.1.1.1 Left FFA2
anova_E1_lFFA2 <- aov_4(meanResp ~ FaceWord * Layout + (1 + FaceWord * Layout | SubjCode),
data = filter(df_univar_agg_E1_FFA2, Label == label_lFFA2_E1))
anova_E1_lFFA2
## Anova Table (Type 3 tests)
##
## Response: meanResp
## Effect df MSE F ges p.value
## 1 FaceWord 1, 13 0.15 1.20 .010 .29
## 2 Layout 2.18, 28.34 0.03 6.90 ** .02 .003
## 3 FaceWord:Layout 2.65, 34.45 0.05 0.31 .002 .79
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '+' 0.1 ' ' 1
##
## Sphericity correction method: GG
emm_anova_E1_lFFA2 <- emmeans(anova_E1_lFFA2, ~ FaceWord * Layout)
emm_anova_E1_lFFA2 %>%
as.data.frame() %>%
arrange(FaceWord)
Posthoc analysis for the main effects:
contrast(emmeans(emm_anova_E1_lFFA2, ~ FaceWord), "pairwise")
## contrast estimate SE df t.ratio p.value
## face - word 0.0804 0.0733 13 1.097 0.2925
##
## Results are averaged over the levels of: Layout
contrast(emmeans(emm_anova_E1_lFFA2, ~ Layout), "pairwise") # , adjust = "none"
## contrast estimate SE df t.ratio p.value
## intact - misconfigured 0.0589 0.0389 39 1.515 0.4387
## intact - top 0.1686 0.0389 39 4.336 0.0006
## intact - bottom 0.0390 0.0389 39 1.004 0.7479
## misconfigured - top 0.1097 0.0389 39 2.821 0.0361
## misconfigured - bottom -0.0198 0.0389 39 -0.511 0.9561
## top - bottom -0.1295 0.0389 39 -3.331 0.0098
##
## Results are averaged over the levels of: FaceWord
## P value adjustment: tukey method for comparing a family of 4 estimates
Results of simple effect analysis (uncorrected):
contr_anova_E1_lFFA2 <- contrast(emm_anova_E1_lFFA2, "pairwise", simple = "each", combine = TRUE, adjust = "none")
# contrast(emm_uni_anova_E1, interaction = "pairwise") # , adjust = "none"
contr_anova_E1_lFFA2
## Layout FaceWord contrast estimate SE df t.ratio p.value
## intact . face - word 0.13568 0.1005 36.5 1.351 0.1851
## misconfigured . face - word 0.04621 0.1005 36.5 0.460 0.6482
## top . face - word 0.09668 0.1005 36.5 0.962 0.3422
## bottom . face - word 0.04317 0.1005 36.5 0.430 0.6699
## . face intact - misconfigured 0.10362 0.0682 69.5 1.519 0.1334
## . face intact - top 0.18806 0.0682 69.5 2.756 0.0075
## . face intact - bottom 0.08530 0.0682 69.5 1.250 0.2154
## . face misconfigured - top 0.08444 0.0682 69.5 1.238 0.2200
## . face misconfigured - bottom -0.01832 0.0682 69.5 -0.269 0.7891
## . face top - bottom -0.10276 0.0682 69.5 -1.506 0.1366
## . word intact - misconfigured 0.01415 0.0682 69.5 0.207 0.8363
## . word intact - top 0.14905 0.0682 69.5 2.185 0.0323
## . word intact - bottom -0.00722 0.0682 69.5 -0.106 0.9160
## . word misconfigured - top 0.13490 0.0682 69.5 1.977 0.0520
## . word misconfigured - bottom -0.02137 0.0682 69.5 -0.313 0.7551
## . word top - bottom -0.15627 0.0682 69.5 -2.290 0.0250
5.2.3.1.1.2 Right FFA2
anova_E1_rFFA2 <- aov_4(meanResp ~ FaceWord * Layout + (1 + FaceWord * Layout | SubjCode),
data = filter(df_univar_agg_E1_FFA2, Label == label_rFFA2_E1))
anova_E1_rFFA2
## Anova Table (Type 3 tests)
##
## Response: meanResp
## Effect df MSE F ges p.value
## 1 FaceWord 1, 15 0.12 18.38 *** .09 .0006
## 2 Layout 2.39, 35.92 0.05 7.30 ** .04 .001
## 3 FaceWord:Layout 2.35, 35.19 0.05 1.89 .009 .16
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '+' 0.1 ' ' 1
##
## Sphericity correction method: GG
emm_anova_E1_rFFA2 <- emmeans(anova_E1_rFFA2, ~ FaceWord * Layout)
emm_anova_E1_rFFA2 %>%
as.data.frame() %>%
arrange(FaceWord)
Posthoc analysis for the main effects:
contrast(emmeans(emm_anova_E1_rFFA2, ~ FaceWord), "pairwise")
## contrast estimate SE df t.ratio p.value
## face - word 0.263 0.0614 15 4.287 0.0006
##
## Results are averaged over the levels of: Layout
contrast(emmeans(emm_anova_E1_rFFA2, ~ Layout), "pairwise") # , adjust = "none"
## contrast estimate SE df t.ratio p.value
## intact - misconfigured 0.2036 0.0487 45 4.185 0.0007
## intact - top 0.1840 0.0487 45 3.783 0.0025
## intact - bottom 0.1597 0.0487 45 3.281 0.0104
## misconfigured - top -0.0196 0.0487 45 -0.403 0.9777
## misconfigured - bottom -0.0440 0.0487 45 -0.904 0.8029
## top - bottom -0.0244 0.0487 45 -0.501 0.9584
##
## Results are averaged over the levels of: FaceWord
## P value adjustment: tukey method for comparing a family of 4 estimates
Results of simple effect analysis (uncorrected):
contr_anova_E1_rFFA2 <- contrast(emm_anova_E1_rFFA2, "pairwise", simple = "each", combine = TRUE, adjust = "none")
# contrast(emm_uni_anova_E1, interaction = "pairwise") # , adjust = "none"
contr_anova_E1_rFFA2
## Layout FaceWord contrast estimate SE df t.ratio p.value
## intact . face - word 0.39107 0.0847 42.6 4.619 <.0001
## misconfigured . face - word 0.17920 0.0847 42.6 2.116 0.0402
## top . face - word 0.26688 0.0847 42.6 3.152 0.0030
## bottom . face - word 0.21625 0.0847 42.6 2.554 0.0143
## . face intact - misconfigured 0.30956 0.0680 90.0 4.549 <.0001
## . face intact - top 0.24613 0.0680 90.0 3.617 0.0005
## . face intact - bottom 0.24706 0.0680 90.0 3.631 0.0005
## . face misconfigured - top -0.06343 0.0680 90.0 -0.932 0.3538
## . face misconfigured - bottom -0.06250 0.0680 90.0 -0.918 0.3608
## . face top - bottom 0.00093 0.0680 90.0 0.014 0.9891
## . word intact - misconfigured 0.09769 0.0680 90.0 1.436 0.1546
## . word intact - top 0.12194 0.0680 90.0 1.792 0.0765
## . word intact - bottom 0.07224 0.0680 90.0 1.062 0.2912
## . word misconfigured - top 0.02426 0.0680 90.0 0.356 0.7223
## . word misconfigured - bottom -0.02545 0.0680 90.0 -0.374 0.7093
## . word top - bottom -0.04970 0.0680 90.0 -0.730 0.4670
5.2.3.1.2 Plot
sig_uni_E1_FFA2 <- c(signif(as.data.frame(contr_anova_E1_lFFA2)[c(5, 11), "p.value"], nDigitals), rep("", 6),
signif(as.data.frame(contr_anova_E1_rFFA2)[c(5, 11), "p.value"], nDigitals), rep("", 6))
color_uni_E1_FFA2 <- sig_colors(sig_uni_E1_FFA2)
# add the column of Hemisphere
nRow_E1 <-nrow(as.data.frame(emm_anova_E1_lFFA2))
Hemisphere <- c(rep("left", nRow_E1), rep("right", nRow_E1))
desp_uni_E1_FFA2 <- cbind(Hemisphere, rbind(as.data.frame(emm_anova_E1_lFFA2), as.data.frame(emm_anova_E1_rFFA2)))
plot_uni_E1_FFA2 <- {
ggplot(data = desp_uni_E1_FFA2, aes(y = emmean, x = Hemisphere, fill = Layout)) + # set the data, varialbes for x and y axises
geom_col(position = "dodge", color = "black", alpha = .7) + # position of columns and countour of columns
facet_grid(FaceWord ~ .) +
geom_errorbar(mapping = aes(ymin = lower.CL, ymax = upper.CL), linetype = 1, # set the error bar
show.legend = FALSE, width = 0.25, alpha = .5,
position = position_dodge(width=0.9)) +
scale_y_continuous(expand= c(0, 0), limits = c(0, activationUL), breaks = seq(0, 3, .5)) + # remove the space between columns and x axis
labs(title = "Mean neural responses in FFA2 (Univariate)", x = "Hemisphere", y = "Beta values") + # set the names for main, x and y axises
geom_text(label = sig_uni_E1_FFA2, color = color_uni_E1_FFA2, size = 5, nudge_y = 0.5, nudge_x = -0.25) + # add starts to the significant columns
general_theme
}
# ggsave('plot_uni_E1_FFA2.png', plot_uni_E1_FFA2, width = 8, height = 5.5)
plot_uni_E1_FFA2
The above figure shows the neural respones (beta values) in FFA2 for each condition. The numbers are the p-values for the tests of differences between intact vs. misconfigued in that condition. Error bars represent 95% confidence intervals.
5.2.3.2 Multivarate analyses (MVPA)
5.2.3.2.1 One-sample t-test
# one-sample for results of mvpa E1 FFA2
one_mvpa_agg_E1_FFA2 <- {
df_mvpa_acc_E1_FFA2 %>%
group_by(Hemisphere, ClassifyPair) %>%
summarize(mean = t.test(Accuracy, mu = 0.5, alternative = "greater")[[5]],
SD = t.test(Accuracy, mu = 0.5, alternative = "greater")[[7]],
t = t.test(Accuracy, mu = 0.5, alternative = "greater")[[1]],
df = t.test(Accuracy, mu = 0.5, alternative = "greater")[[2]],
p = round(t.test(Accuracy, mu = 0.5, alternative = "greater")[[3]], 5),
lower.CL = t.test(Accuracy, mu = 0.5, alternative = "greater")[[4]][1],
upper.CL = mean * 2 - lower.CL, # t.test(Accuracy, mu = 0.5, alternative = "two.sided")[[4]][2],
nullValue = t.test(Accuracy, mu = 0.5, alternative = "greater")[[6]],
alternative = t.test(Accuracy, mu = 0.5, alternative = "greater")[[8]]
)
}
one_mvpa_agg_E1_FFA2
5.2.3.2.2 Plot
plot_mvpa_E1_FFA2 <- {
ggplot(data = one_mvpa_agg_E1_FFA2, aes(y = mean, x = ClassifyPair, fill = ClassifyPair)) + # set the data, varialbes for x and y axises
geom_col(position = "dodge", color = "black", alpha = .7) + # position of columns and countour of columns
facet_grid(. ~ Hemisphere) +
scale_fill_manual(values = mvpaColors) +
geom_errorbar(mapping = aes(ymin = lower.CL, ymax = upper.CL), linetype = 1, # set the error bar
show.legend = FALSE, width = 0.25, alpha = .5,
position = position_dodge(width=0.9)) +
geom_hline(yintercept = c(0.5, 1), linetype = 5, alpha = 0.5) + # add the line for 0.5 and 1 (y)
scale_y_continuous(expand= c(0, 0), limits = c(0, 1.1), breaks = seq(0, 1, .25)) + # remove the space between columns and x axis
labs(title = "Decoding accuracy in FFA2", x = "Classification Pairs", y = "Accuracy") + # set the names for main, x and y axises Subjective Responses for E205
geom_text(label = signif(one_mvpa_agg_E1_FFA2$p), color = sig_colors(one_mvpa_agg_E1_FFA2$p), size = sig_size, nudge_y = 0.15) + # add starts to the significant columns
general_theme +
theme(axis.title.x=element_blank(),
axis.text.x=element_blank(),
axis.ticks.x=element_blank(),
axis.line = element_line(size = 3))
# theme(axis.text.x = element_text(angle = 90, vjust=.5, hjust = 1), #
# axis.line = element_line(size = 3))
}
# ggsave('plot_mvpa_E1_FFA2.png', plot_mvpa_E1_FFA2, width = 12, height = 5)
plot_mvpa_E1_FFA2
The above figure shows the decoding accuracy in FFA2 for each pair. The numbers are the p-values for the one-tail one-sample t-tests against the chance level (0.5) in that condition. Error bars represent 95% confidence intervals.
5.2.3.3 Similarity of top + bottom to intact vs. misconfigured
5.2.3.3.1 One-sample t-test
# Similarity of top + bottom to intact vs. misconfigured in FFA
one_simi_E1_FFA2 <- {
df_simi_rate_E1_FFA2 %>%
group_by(Hemisphere, Combination) %>%
summarize(mean = t.test(RateAsMiscon, mu = 0.5)[[5]],
SD = t.test(RateAsMiscon, mu = 0.5)[[7]],
t = t.test(RateAsMiscon, mu = 0.5)[[1]],
df = t.test(RateAsMiscon, mu = 0.5)[[2]],
p = round(t.test(RateAsMiscon, mu = 0.5)[[3]], 5),
lower.CL = t.test(RateAsMiscon, mu = 0.5)[[4]][1],
upper.CL = t.test(RateAsMiscon, mu = 0.5)[[4]][2],
nullValue = t.test(RateAsMiscon, mu = 0.5)[[6]],
alternative = t.test(RateAsMiscon, mu = 0.5)[[8]]
)
}
one_simi_E1_FFA2
5.2.3.3.2 Plot
plot_simi_E1_FFA2 <- {
ggplot(data = one_simi_E1_FFA2, aes(y = mean, x = Combination, fill = Combination)) + # set the data, varialbes for x and y axises
geom_col(position = "dodge", color = "black", alpha = .7) + # position of columns and countour of columns
facet_grid(. ~ Hemisphere) +
geom_errorbar(mapping = aes(ymin = lower.CL, ymax = upper.CL), linetype = 1, # set the error bar
show.legend = FALSE, width = 0.25, alpha = .5,
position = position_dodge(width=0.9)) +
scale_fill_manual(values = simiColors) +
geom_hline(yintercept = c(0.5, 1), linetype = 5, alpha = 0.5) + # add the line for 0.5 and 1 (y)
scale_y_continuous(expand= c(0, 0), limits = c(0, 1.1), breaks = seq(0, 1, .25)) + # remove the space between columns and x axis
# scale_x_discrete(labels = function(x) str_wrap(x, width = 10)) + # show x labels in two rows
labs(title = "Similarity of top+bottom to intact vs. misconfigured in FFA2", x = "Combinations", y = "Rate of Decoding as Misconfigured") + # set the names for main, x and y axises
geom_text(label = signif(one_simi_E1_FFA2$p, 4), color = sig_colors(one_simi_E1_FFA2$p), size = sig_size, nudge_y = 0.25) + # add starts to the significant columns
general_theme +
theme(axis.title.x=element_blank(),
axis.text.x=element_blank(),
axis.ticks.x=element_blank(),
axis.line = element_line(size = 4))
# theme(axis.text.x = element_text(angle = 90, vjust=.5, hjust = 1), #
# axis.line = element_line(size = 3))
}
# ggsave('plot_simi_E1_FFA2.png', plot_simi_E1_FFA2, width = 14, height = 5)
plot_simi_E1_FFA2
The above figure shows the probability of top+bottom being decoded as misconfigued conditions in FFA2. Patterns of top and bottom were combined with different weights, i.e., “face_top0.25-face_bottom0.75” denotes the linear combinations of face_top and face_bottom with the weights of 0.25/0.75. The numbers are the p-values for the two-tail one-sample t-tests against the chance level (0.5) in that condition. Error bars represent 95% confidence intervals.
5.2.4 Label: left Visual Word Form Area (VWFA)
# label_VWFA_E1 <- label_lVWFA[1] # "roi.lh.f13.w-vs-o.label"
The label used for (left) VWFA in Experiment 1 is roi.lh.f13.w-vs-o.label.
# only keep data for these two labels
df_univar_agg_E1_VWFA <- filter(df_univar_agg_E1, Label %in% label_VWFA_E1)
df_mvpa_acc_E1_VWFA <- filter(df_mvpa_acc_E1, Label %in% label_VWFA_E1)
df_simi_rate_E1_VWFA <- filter(df_rate_simi_E1, Label %in% label_VWFA_E1)
# subjects used for each hemisphere
# unique(as.character((df_univar_agg_E1_VWFA %>% filter(Label == label_VWFA_E1))$SubjCode))
df_univar_agg_E1_VWFA %>%
select(ExpCode, Hemisphere, Label, SubjCode) %>%
distinct() %>%
group_by(ExpCode, Hemisphere, Label) %>%
summarize(Count = n())
5.2.4.1 Univariate analyses
5.2.4.1.1 rm-ANOVA
anova_E1_VWFA <- aov_4(meanResp ~ FaceWord * Layout + (1 + FaceWord * Layout | SubjCode),
data = filter(df_univar_agg_E1_VWFA, Label == label_VWFA_E1))
anova_E1_VWFA
## Anova Table (Type 3 tests)
##
## Response: meanResp
## Effect df MSE F ges p.value
## 1 FaceWord 1, 17 0.22 54.76 *** .15 <.0001
## 2 Layout 2.63, 44.73 0.05 2.65 + .005 .07
## 3 FaceWord:Layout 2.54, 43.17 0.04 9.16 *** .01 .0002
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '+' 0.1 ' ' 1
##
## Sphericity correction method: GG
emm_anova_E1_VWFA <- emmeans(anova_E1_VWFA, ~ FaceWord * Layout)
emm_anova_E1_VWFA %>%
as.data.frame() %>%
arrange(FaceWord)
Posthoc analysis for the main effects:
contrast(emmeans(emm_anova_E1_VWFA, ~ FaceWord), "pairwise")
## contrast estimate SE df t.ratio p.value
## face - word -0.581 0.0785 17 -7.400 <.0001
##
## Results are averaged over the levels of: Layout
contrast(emmeans(emm_anova_E1_VWFA, ~ Layout), "pairwise") # , adjust = "none"
## contrast estimate SE df t.ratio p.value
## intact - misconfigured 0.0298 0.0494 51 0.604 0.9304
## intact - top 0.1305 0.0494 51 2.643 0.0516
## intact - bottom 0.0748 0.0494 51 1.514 0.4366
## misconfigured - top 0.1007 0.0494 51 2.039 0.1874
## misconfigured - bottom 0.0450 0.0494 51 0.911 0.7993
## top - bottom -0.0557 0.0494 51 -1.128 0.6739
##
## Results are averaged over the levels of: FaceWord
## P value adjustment: tukey method for comparing a family of 4 estimates
Results of simple effect analysis (uncorrected):
contr_anova_E1_VWFA <- contrast(emm_anova_E1_VWFA, "pairwise", simple = "each", combine = TRUE, adjust = "none")
# contrast(emm_uni_anova_E1, interaction = "pairwise") # , adjust = "none"
contr_anova_E1_VWFA
## Layout FaceWord contrast estimate SE df t.ratio p.value
## intact . face - word -0.4644 0.0929 31.7 -4.999 <.0001
## misconfigured . face - word -0.7228 0.0929 31.7 -7.781 <.0001
## top . face - word -0.4001 0.0929 31.7 -4.307 0.0001
## bottom . face - word -0.7361 0.0929 31.7 -7.923 <.0001
## . face intact - misconfigured 0.1590 0.0639 98.3 2.489 0.0145
## . face intact - top 0.0983 0.0639 98.3 1.539 0.1271
## . face intact - bottom 0.2106 0.0639 98.3 3.295 0.0014
## . face misconfigured - top -0.0607 0.0639 98.3 -0.950 0.3445
## . face misconfigured - bottom 0.0516 0.0639 98.3 0.807 0.4217
## . face top - bottom 0.1123 0.0639 98.3 1.757 0.0821
## . word intact - misconfigured -0.0994 0.0639 98.3 -1.556 0.1230
## . word intact - top 0.1626 0.0639 98.3 2.545 0.0125
## . word intact - bottom -0.0611 0.0639 98.3 -0.956 0.3415
## . word misconfigured - top 0.2620 0.0639 98.3 4.100 0.0001
## . word misconfigured - bottom 0.0383 0.0639 98.3 0.600 0.5499
## . word top - bottom -0.2237 0.0639 98.3 -3.500 0.0007
5.2.4.1.2 Plot
sig_uni_E1_VWFA <- c(signif(as.data.frame(contr_anova_E1_VWFA)[c(5, 11), "p.value"], nDigitals), rep("", 6))
color_uni_E1_VWFA <- sig_colors(sig_uni_E1_VWFA)
plot_uni_E1_VWFA <- {
ggplot(data = as.data.frame(emm_anova_E1_VWFA), aes(y = emmean, x = FaceWord, fill = Layout)) + # set the data, varialbes for x and y axises
geom_col(position = "dodge", color = "black", alpha = .7) + # position of columns and countour of columns
# facet_grid(FaceWord ~ .) +
geom_errorbar(mapping = aes(ymin = lower.CL, ymax = upper.CL), linetype = 1, # set the error bar
show.legend = FALSE, width = 0.25, alpha = .5,
position = position_dodge(width=0.9)) +
scale_y_continuous(expand= c(0, 0), limits = c(0, activationUL), breaks = seq(0, 3, .5)) + # remove the space between columns and x axis
labs(title = "Mean neural responses in (left) VWFA (Univariate)", x = "Stimuli", y = "Beta values") + # set the names for main, x and y axises
geom_text(label = sig_uni_E1_VWFA, color = color_uni_E1_VWFA, size = 5, nudge_y = 0.5, nudge_x = -0.25) + # add starts to the significant columns
general_theme
}
# ggsave('plot_uni_E1_VWFA.png', plot_uni_E1_VWFA, width = 8, height = 4)
plot_uni_E1_VWFA
The above figure shows the neural respones (beta values) in VWFA for each condition. The numbers are the p-values for the tests of differences between intact vs. misconfigued in that condition. Error bars represent 95% confidence intervals.
5.2.4.2 Multivarate analyses (MVPA)
5.2.4.2.1 One-sample t-test
# one-sample for results of mvpa E1 VWFA
one_mvpa_agg_E1_VWFA <- {
df_mvpa_acc_E1_VWFA %>%
group_by(Hemisphere, ClassifyPair) %>%
summarize(mean = t.test(Accuracy, mu = 0.5, alternative = "greater")[[5]],
SD = t.test(Accuracy, mu = 0.5, alternative = "greater")[[7]],
t = t.test(Accuracy, mu = 0.5, alternative = "greater")[[1]],
df = t.test(Accuracy, mu = 0.5, alternative = "greater")[[2]],
p = round(t.test(Accuracy, mu = 0.5, alternative = "greater")[[3]], 5),
lower.CL = t.test(Accuracy, mu = 0.5, alternative = "greater")[[4]][1],
upper.CL = mean * 2 - lower.CL, # t.test(Accuracy, mu = 0.5, alternative = "two.sided")[[4]][2],
nullValue = t.test(Accuracy, mu = 0.5, alternative = "greater")[[6]],
alternative = t.test(Accuracy, mu = 0.5, alternative = "greater")[[8]]
)
}
one_mvpa_agg_E1_VWFA
5.2.4.2.2 Plot
color_uni_E1_VWFA <-
plot_mvpa_E1_VWFA <- {
ggplot(data = one_mvpa_agg_E1_VWFA, aes(y = mean, x = ClassifyPair, fill = ClassifyPair)) + # set the data, varialbes for x and y axises
geom_col(position = "dodge", color = "black", alpha = .7) + # position of columns and countour of columns
facet_grid(. ~ Hemisphere) +
scale_fill_manual(values = mvpaColors) +
geom_errorbar(mapping = aes(ymin = lower.CL, ymax = upper.CL), linetype = 1, # set the error bar
show.legend = FALSE, width = 0.25, alpha = .5,
position = position_dodge(width=0.9)) +
geom_hline(yintercept = c(0.5, 1), linetype = 5, alpha = 0.5) + # add the line for 0.5 and 1 (y)
scale_y_continuous(expand= c(0, 0), limits = c(0, 1.1), breaks = seq(0, 1, .25)) + # remove the space between columns and x axis
# scale_x_discrete(labels = function(x) str_wrap(x, width = 10)) + # show x labels in two rows
labs(title = "Decoding accuracy in VWFA", x = "Classification Pairs", y = "Accuracy") + # set the names for main, x and y axises
geom_text(label = signif(one_mvpa_agg_E1_VWFA$p), color = sig_colors(one_mvpa_agg_E1_VWFA$p), size = sig_size, nudge_y = 0.15) + # add starts to the significant columns
general_theme +
theme(axis.title.x=element_blank(),
axis.text.x=element_blank(),
axis.ticks.x=element_blank(),
axis.line = element_line(size = 3))
# theme(axis.text.x = element_text(angle = 90, vjust=.5, hjust = 1), #
# axis.line = element_line(size = 3))
}
# ggsave('plot_mvpa_E1_VWFA.png', plot_mvpa_E1_VWFA, width = 9, height = 5)
plot_mvpa_E1_VWFA
The above figure shows the decoding accuracy in VWFA for each pair. The numbers are the p-values for the one-tail one-sample t-tests against the chance level (0.5) in that condition. Error bars represent 95% confidence intervals.
5.2.4.3 Similarity of top + bottom to intact vs. misconfigured
5.2.4.3.1 One-sample t-test
# Similarity of top + bottom to intact vs. misconfigured in VWFA
one_simi_E1_VWFA <- {
df_simi_rate_E1_VWFA %>%
group_by(Hemisphere, Combination) %>%
summarize(mean = t.test(RateAsMiscon, mu = 0.5)[[5]],
SD = t.test(RateAsMiscon, mu = 0.5)[[7]],
t = t.test(RateAsMiscon, mu = 0.5)[[1]],
df = t.test(RateAsMiscon, mu = 0.5)[[2]],
p = round(t.test(RateAsMiscon, mu = 0.5)[[3]], 5),
lower.CL = t.test(RateAsMiscon, mu = 0.5)[[4]][1],
upper.CL = t.test(RateAsMiscon, mu = 0.5)[[4]][2],
nullValue = t.test(RateAsMiscon, mu = 0.5)[[6]],
alternative = t.test(RateAsMiscon, mu = 0.5)[[8]]
)
}
one_simi_E1_VWFA
5.2.4.3.2 Plot
plot_simi_E1_VWFA <- {
ggplot(data = one_simi_E1_VWFA, aes(y = mean, x = Combination, fill = Combination)) + # set the data, varialbes for x and y axises
geom_col(position = "dodge", color = "black", alpha = .7) + # position of columns and countour of columns
facet_grid(. ~ Hemisphere) +
geom_errorbar(mapping = aes(ymin = lower.CL, ymax = upper.CL), linetype = 1, # set the error bar
show.legend = FALSE, width = 0.25, alpha = .5,
position = position_dodge(width=0.9)) +
scale_fill_manual(values = simiColors) +
geom_hline(yintercept = c(0.5, 1), linetype = 5, alpha = 0.5) + # add the line for 0.5 and 1 (y)
scale_y_continuous(expand= c(0, 0), limits = c(0, 1.1), breaks = seq(0, 1, .25)) + # remove the space between columns and x axis
# scale_x_discrete(labels = function(x) str_wrap(x, width = 10)) + # show x labels in two rows
labs(title = "Similarity of top+bottom to intact vs. misconfigured in VWFA", x = "Combinations", y = "Rate of Decoding as Misconfigured") + # set the names for main, x and y axises
geom_text(label = signif(one_simi_E1_VWFA$p, 4), color = sig_colors(one_simi_E1_VWFA$p), size = sig_size, nudge_y = 0.25) + # add starts to the significant columns
general_theme +
theme(axis.title.x=element_blank(),
axis.text.x=element_blank(),
axis.ticks.x=element_blank(),
axis.line = element_line(size = 4))
# theme(axis.text.x = element_text(angle = 90, vjust=.5, hjust = 1), #
# axis.line = element_line(size = 3))
}
# ggsave('plot_simi_E1_VWFA.png', plot_simi_E1_VWFA, width = 10, height = 5)
plot_simi_E1_VWFA
The above figure shows the probability of top+bottom being decoded as misconfigued conditions in VWFA. Patterns of top and bottom were combined with different weights, i.e., “face_top0.25-face_bottom0.75” denotes the linear combinations of face_top and face_bottom with the weights of 0.25/0.75. The numbers are the p-values for the two-tail one-sample t-tests against the chance level (0.5) in that condition. Error bars represent 95% confidence intervals.
5.2.5 Label:Lateral Occipital Cortex
# label_lLOC_E1 <- label_lLOC[1] #
# label_rLOC_E1 <- label_rLOC[1] #
label_LOC_E1 <- c(label_lLOC_E1, label_rLOC_E1)
The label used for left LOC in Experiment 1 is roi.lh.f13.o-vs-scr.label.
The label used for right LOC in Experiment 1 is roi.rh.f13.o-vs-scr.label.
# only keep data for these two labels
df_univar_agg_E1_LOC <- filter(df_univar_agg_E1, Label %in% label_LOC_E1)
df_mvpa_acc_E1_LOC <- filter(df_mvpa_acc_E1, Label %in% label_LOC_E1)
df_simi_rate_E1_LOC <- filter(df_rate_simi_E1, Label %in% label_LOC_E1)
# subjects used for each hemisphere
# unique(as.character((df_univar_agg_E1_LOC %>% filter(Label == label_lLOC_E1))$SubjCode))
df_univar_agg_E1_LOC %>%
select(ExpCode, Hemisphere, Label, SubjCode) %>%
distinct() %>%
group_by(ExpCode, Hemisphere, Label) %>%
summarize(Count = n())
5.2.5.1 Univariate analyses
5.2.5.1.1 rm-ANOVA
5.2.5.1.1.1 Left LOC
anova_E1_lLOC <- aov_4(meanResp ~ FaceWord * Layout + (1 + FaceWord * Layout | SubjCode),
data = filter(df_univar_agg_E1_LOC, Label == label_lLOC_E1))
anova_E1_lLOC
## Anova Table (Type 3 tests)
##
## Response: meanResp
## Effect df MSE F ges p.value
## 1 FaceWord 1, 18 0.18 21.31 *** .07 .0002
## 2 Layout 2.10, 37.88 0.05 0.43 .0009 .66
## 3 FaceWord:Layout 2.29, 41.17 0.04 0.03 <.0001 .98
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '+' 0.1 ' ' 1
##
## Sphericity correction method: GG
emm_anova_E1_lLOC <- emmeans(anova_E1_lLOC, ~ FaceWord * Layout)
emm_anova_E1_lLOC %>%
as.data.frame() %>%
arrange(FaceWord)
Posthoc analysis for the main effects:
contrast(emmeans(emm_anova_E1_lLOC, ~ FaceWord), "pairwise")
## contrast estimate SE df t.ratio p.value
## face - word -0.317 0.0687 18 -4.616 0.0002
##
## Results are averaged over the levels of: Layout
contrast(emmeans(emm_anova_E1_lLOC, ~ Layout), "pairwise") # , adjust = "none"
## contrast estimate SE df t.ratio p.value
## intact - misconfigured 0.03553 0.042 54 0.846 0.8323
## intact - top 0.04271 0.042 54 1.017 0.7404
## intact - bottom 0.03793 0.042 54 0.903 0.8033
## misconfigured - top 0.00718 0.042 54 0.171 0.9982
## misconfigured - bottom 0.00240 0.042 54 0.057 0.9999
## top - bottom -0.00478 0.042 54 -0.114 0.9995
##
## Results are averaged over the levels of: FaceWord
## P value adjustment: tukey method for comparing a family of 4 estimates
Results of simple effect analysis (uncorrected):
contr_anova_E1_lLOC <- contrast(emm_anova_E1_lLOC, "pairwise", simple = "each", combine = TRUE, adjust = "none")
# contrast(emm_uni_anova_E1, interaction = "pairwise") # , adjust = "none"
contr_anova_E1_lLOC
## Layout FaceWord contrast estimate SE df t.ratio p.value
## intact . face - word -0.32384 0.0844 37.7 -3.836 0.0005
## misconfigured . face - word -0.30978 0.0844 37.7 -3.669 0.0007
## top . face - word -0.30720 0.0844 37.7 -3.639 0.0008
## bottom . face - word -0.32860 0.0844 37.7 -3.892 0.0004
## . face intact - misconfigured 0.02850 0.0580 107.8 0.491 0.6243
## . face intact - top 0.03438 0.0580 107.8 0.593 0.5546
## . face intact - bottom 0.04031 0.0580 107.8 0.695 0.4887
## . face misconfigured - top 0.00589 0.0580 107.8 0.101 0.9194
## . face misconfigured - bottom 0.01181 0.0580 107.8 0.204 0.8391
## . face top - bottom 0.00592 0.0580 107.8 0.102 0.9189
## . word intact - misconfigured 0.04256 0.0580 107.8 0.734 0.4648
## . word intact - top 0.05103 0.0580 107.8 0.880 0.3810
## . word intact - bottom 0.03555 0.0580 107.8 0.613 0.5413
## . word misconfigured - top 0.00847 0.0580 107.8 0.146 0.8842
## . word misconfigured - bottom -0.00701 0.0580 107.8 -0.121 0.9040
## . word top - bottom -0.01548 0.0580 107.8 -0.267 0.7901
5.2.5.1.1.2 Right LOC
anova_E1_rLOC <- aov_4(meanResp ~ FaceWord * Layout + (1 + FaceWord * Layout | SubjCode),
data = filter(df_univar_agg_E1_LOC, Label == label_rLOC_E1))
anova_E1_rLOC
## Anova Table (Type 3 tests)
##
## Response: meanResp
## Effect df MSE F ges p.value
## 1 FaceWord 1, 16 0.25 3.70 + .01 .07
## 2 Layout 2.26, 36.17 0.08 0.71 .002 .52
## 3 FaceWord:Layout 2.40, 38.42 0.05 0.41 .0006 .71
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '+' 0.1 ' ' 1
##
## Sphericity correction method: GG
emm_anova_E1_rLOC <- emmeans(anova_E1_rLOC, ~ FaceWord * Layout)
emm_anova_E1_rLOC %>%
as.data.frame() %>%
arrange(FaceWord)
Posthoc analysis for the main effects:
contrast(emmeans(emm_anova_E1_rLOC, ~ FaceWord), "pairwise")
## contrast estimate SE df t.ratio p.value
## face - word -0.166 0.0861 16 -1.923 0.0725
##
## Results are averaged over the levels of: Layout
contrast(emmeans(emm_anova_E1_rLOC, ~ Layout), "pairwise") # , adjust = "none"
## contrast estimate SE df t.ratio p.value
## intact - misconfigured 0.082239 0.0595 48 1.381 0.5172
## intact - top 0.060637 0.0595 48 1.018 0.7396
## intact - bottom 0.060014 0.0595 48 1.008 0.7456
## misconfigured - top -0.021602 0.0595 48 -0.363 0.9835
## misconfigured - bottom -0.022225 0.0595 48 -0.373 0.9821
## top - bottom -0.000623 0.0595 48 -0.010 1.0000
##
## Results are averaged over the levels of: FaceWord
## P value adjustment: tukey method for comparing a family of 4 estimates
Results of simple effect analysis (uncorrected):
contr_anova_E1_rLOC <- contrast(emm_anova_E1_rLOC, "pairwise", simple = "each", combine = TRUE, adjust = "none")
# contrast(emm_uni_anova_E1, interaction = "pairwise") # , adjust = "none"
contr_anova_E1_rLOC
## Layout FaceWord contrast estimate SE df t.ratio p.value
## intact . face - word -0.11262 0.1039 31.7 -1.084 0.2867
## misconfigured . face - word -0.21399 0.1039 31.7 -2.059 0.0478
## top . face - word -0.15496 0.1039 31.7 -1.491 0.1458
## bottom . face - word -0.18075 0.1039 31.7 -1.739 0.0917
## . face intact - misconfigured 0.13293 0.0762 91.5 1.745 0.0843
## . face intact - top 0.08181 0.0762 91.5 1.074 0.2856
## . face intact - bottom 0.09408 0.0762 91.5 1.235 0.2199
## . face misconfigured - top -0.05112 0.0762 91.5 -0.671 0.5038
## . face misconfigured - bottom -0.03885 0.0762 91.5 -0.510 0.6112
## . face top - bottom 0.01227 0.0762 91.5 0.161 0.8724
## . word intact - misconfigured 0.03155 0.0762 91.5 0.414 0.6797
## . word intact - top 0.03946 0.0762 91.5 0.518 0.6056
## . word intact - bottom 0.02595 0.0762 91.5 0.341 0.7341
## . word misconfigured - top 0.00791 0.0762 91.5 0.104 0.9175
## . word misconfigured - bottom -0.00560 0.0762 91.5 -0.074 0.9415
## . word top - bottom -0.01351 0.0762 91.5 -0.177 0.8596
5.2.5.1.2 Plot
sig_uni_E1_LOC <- c(signif(as.data.frame(contr_anova_E1_lLOC)[c(5, 11), "p.value"], nDigitals), rep("", 6),
signif(as.data.frame(contr_anova_E1_rLOC)[c(5, 11), "p.value"], nDigitals), rep("", 6))
color_uni_E1_LOC <- sig_colors(sig_uni_E1_LOC)
# add the column of Hemisphere
nRow_E1 <-nrow(as.data.frame(emm_anova_E1_lLOC))
Hemisphere <- c(rep("left", nRow_E1), rep("right", nRow_E1))
desp_uni_E1_LOC <- cbind(Hemisphere, rbind(as.data.frame(emm_anova_E1_lLOC), as.data.frame(emm_anova_E1_rLOC)))
plot_uni_E1_LOC <- {
ggplot(data = desp_uni_E1_LOC, aes(y = emmean, x = Hemisphere, fill = Layout)) + # set the data, varialbes for x and y axises
geom_col(position = "dodge", color = "black", alpha = .7) + # position of columns and countour of columns
facet_grid(FaceWord ~ .) +
geom_errorbar(mapping = aes(ymin = lower.CL, ymax = upper.CL), linetype = 1, # set the error bar
show.legend = FALSE, width = 0.25, alpha = .5,
position = position_dodge(width=0.9)) +
scale_y_continuous(expand= c(0, 0), limits = c(0, activationUL), breaks = seq(0, 3, .5)) + # remove the space between columns and x axis
labs(title = "Mean neural responses in LOC (Univariate)", x = "Hemisphere", y = "Beta values") + # set the names for main, x and y axises Subjective Responses for E205
geom_text(label = sig_uni_E1_LOC, color = color_uni_E1_LOC, size = 5, nudge_y = 0.5, nudge_x = -0.25) + # add starts to the significant columns
general_theme
}
# ggsave('plot_uni_E1_LOC.png', plot_uni_E1_LOC, width = 8, height = 5.5)
plot_uni_E1_LOC
The above figure shows the neural respones (beta values) in LOC for each condition. The numbers are the p-values for the tests of differences between intact vs. misconfigued in that condition. Error bars represent 95% confidence intervals.
5.2.5.2 Multivarate analyses (MVPA)
5.2.5.2.1 One-sample t-test
# one-sample for results of mvpa E1 LOC
one_mvpa_agg_E1_LOC <- {
df_mvpa_acc_E1_LOC %>%
group_by(Hemisphere, ClassifyPair) %>%
summarize(mean = t.test(Accuracy, mu = 0.5, alternative = "greater")[[5]],
SD = t.test(Accuracy, mu = 0.5, alternative = "greater")[[7]],
t = t.test(Accuracy, mu = 0.5, alternative = "greater")[[1]],
df = t.test(Accuracy, mu = 0.5, alternative = "greater")[[2]],
p = round(t.test(Accuracy, mu = 0.5, alternative = "greater")[[3]], 5),
lower.CL = t.test(Accuracy, mu = 0.5, alternative = "greater")[[4]][1],
upper.CL = mean * 2 - lower.CL, # t.test(Accuracy, mu = 0.5, alternative = "two.sided")[[4]][2],
nullValue = t.test(Accuracy, mu = 0.5, alternative = "greater")[[6]],
alternative = t.test(Accuracy, mu = 0.5, alternative = "greater")[[8]]
)
}
one_mvpa_agg_E1_LOC
5.2.5.2.2 Plot
plot_mvpa_E1_LOC <- {
ggplot(data = one_mvpa_agg_E1_LOC, aes(y = mean, x = ClassifyPair, fill = ClassifyPair)) + # set the data, varialbes for x and y axises
geom_col(position = "dodge", color = "black", alpha = .7) + # position of columns and countour of columns
facet_grid(. ~ Hemisphere) +
scale_fill_manual(values = mvpaColors) +
geom_errorbar(mapping = aes(ymin = lower.CL, ymax = upper.CL), linetype = 1, # set the error bar
show.legend = FALSE, width = 0.25, alpha = .5,
position = position_dodge(width=0.9)) +
geom_hline(yintercept = c(0.5, 1), linetype = 5, alpha = 0.5) + # add the line for 0.5 and 1 (y)
scale_y_continuous(expand= c(0, 0), limits = c(0, 1.1), breaks = seq(0, 1, .25)) + # remove the space between columns and x axis
# scale_x_discrete(labels = function(x) str_wrap(x, width = 10)) + # show x labels in two rows
labs(title = "", x = "Classification Pairs", y = "Accuracy") + # set the names for main, x and y axises Subjective Responses for E205
geom_text(label = signif(one_mvpa_agg_E1_LOC$p), color = sig_colors(one_mvpa_agg_E1_LOC$p), size = sig_size, nudge_y = 0.15) + # add starts to the significant columns
general_theme +
theme(axis.title.x=element_blank(),
axis.text.x=element_blank(),
axis.ticks.x=element_blank(),
axis.line = element_line(size = 3))
# theme(axis.text.x = element_text(angle = 90, vjust=.5, hjust = 1), #
# axis.line = element_line(size = 3))
}
# ggsave('plot_mvpa_E1_LOC.png', plot_mvpa_E1_LOC, width = 12, height = 5)
plot_mvpa_E1_LOC
The above figure shows the decoding accuracy in LOC for each pair. The numbers are the p-values for the one-tail one-sample t-tests against the chance level (0.5) in that condition. Error bars represent 95% confidence intervals.
5.2.5.3 Similarity of top + bottom to intact vs. misconfigured
5.2.5.3.1 One-sample t-test
# Similarity of top + bottom to intact vs. misconfigured in LOC
one_simi_E1_LOC <- {
df_simi_rate_E1_LOC %>%
group_by(Hemisphere, Combination) %>%
summarize(mean = t.test(RateAsMiscon, mu = 0.5)[[5]],
SD = t.test(RateAsMiscon, mu = 0.5)[[7]],
t = t.test(RateAsMiscon, mu = 0.5)[[1]],
df = t.test(RateAsMiscon, mu = 0.5)[[2]],
p = round(t.test(RateAsMiscon, mu = 0.5)[[3]], 5),
lower.CL = t.test(RateAsMiscon, mu = 0.5)[[4]][1],
upper.CL = t.test(RateAsMiscon, mu = 0.5)[[4]][2],
nullValue = t.test(RateAsMiscon, mu = 0.5)[[6]],
alternative = t.test(RateAsMiscon, mu = 0.5)[[8]]
)
}
one_simi_E1_LOC
5.2.5.3.2 Plot
plot_simi_E1_LOC <- {
ggplot(data = one_simi_E1_LOC, aes(y = mean, x = Combination, fill = Combination)) + # set the data, varialbes for x and y axises
geom_col(position = "dodge", color = "black", alpha = .7) + # position of columns and countour of columns
facet_grid(. ~ Hemisphere) +
geom_errorbar(mapping = aes(ymin = lower.CL, ymax = upper.CL), linetype = 1, # set the error bar
show.legend = FALSE, width = 0.25, alpha = .5,
position = position_dodge(width=0.9)) +
scale_fill_manual(values = simiColors) +
geom_hline(yintercept = c(0.5, 1), linetype = 5, alpha = 0.5) + # add the line for 0.5 and 1 (y)
scale_y_continuous(expand= c(0, 0), limits = c(0, 1.1), breaks = seq(0, 1, .25)) + # remove the space between columns and x axis
# scale_x_discrete(labels = function(x) str_wrap(x, width = 10)) + # show x labels in two rows
labs(title = "Similarity of top+bottom to intact vs. misconfigured in LOC", x = "Combinations", y = "Rate of Decoding as Misconfigured") + # set the names for main, x and y axises
geom_text(label = signif(one_simi_E1_LOC$p, 4), color = sig_colors(one_simi_E1_LOC$p), size = sig_size, nudge_y = 0.25) + # add starts to the significant columns
general_theme +
theme(axis.title.x=element_blank(),
axis.text.x=element_blank(),
axis.ticks.x=element_blank(),
axis.line = element_line(size = 4))
# theme(axis.text.x = element_text(angle = 90, vjust=.5, hjust = 1), #
# axis.line = element_line(size = 3))
}
# ggsave('plot_simi_E1_LOC.png', plot_simi_E1_LOC, width = 14, height = 5)
plot_simi_E1_LOC
The above figure shows the probability of top+bottom being decoded as misconfigued conditions in LOC. Patterns of top and bottom were combined with different weights, i.e., “face_top0.25-face_bottom0.75” denotes the linear combinations of face_top and face_bottom with the weights of 0.25/0.75. The numbers are the p-values for the two-tail one-sample t-tests against the chance level (0.5) in that condition. Error bars represent 95% confidence intervals.